<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>向HTML中添加新元素</title>
  <script>
    document.createElement("my")
  </script>
  <style>
    my{
      display: block;
      background-color: #ddd;
      padding: 50px;
      font-size: 30px;
    }
  </style>
</head>
<body>
<h2>123456</h2>
<my>123456</my>
</body>
</html>